package com.smmisia.shop.request;

import com.smmisia.common.request.BaseRequest;
import com.smmisia.shop.constant.ProductEvent;
import jakarta.validation.constraints.NotNull;
import lombok.*;


/**
 * author: smmisia
 */
@Getter
@Setter
@NoArgsConstructor
@AllArgsConstructor
public abstract class BaseProductRequest extends BaseRequest {

    /**
     * 幂等号
     */
    @NotNull(message = "identifier is not null")
    private String identifier;

    /**
     * '商品id'
     */
    private Long productId;

    /**
     * 获取事件类型
     * @return
     */
    public abstract ProductEvent getEventType();
}
